﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Collections.Specialized;
using System.Reflection;

namespace Domain.MainModule.Entities
{
    public partial class Order
    {
        public void ChargeEntity(NameValueCollection collection)
        {
            foreach (string key in collection.AllKeys)
            {
                PropertyInfo pinfo = GetType().GetProperty(key);
                pinfo.SetValue(this, collection[key], null);
            }
        }
    }
}
